<template>
  <div>
    <div
      style="width:30px;position: absolute;
    right: 2px;"
      @click="clickimg()"
    >
      <img src="../../assets/img/ping.png" style="width:100%" />
    </div>
    <iframe
      :src="
        'https://console.huaweicloud.com/dlv/vision/share/?id=00b5330241ec403faeb4920180d71a66&locale=zh-cn&region=cn-south-1#selfWarzoneCode=' +
          this.selfWarzoneCode
      "
      width
      height
      frameborder="0"
      name="iframe名称"
      scrolling="no"
    ></iframe>
  </div>
</template>

<script>
export default {
  data() {
    return {
      logininfo: {},
      token: '',
      orgSeq: '',
      orgType: '',
      selfWarzoneCode: '',
    };
  },
  created() {},
  mounted() {
    this.logininfo = localStorage.getItem('logininfo');
    let orgJson = JSON.parse(this.logininfo);
    if (
      orgJson != null &&
      orgJson.orgList != null &&
      orgJson.orgList.length > 0
    ) {
      this.orgSeq = orgJson.orgList[0].orgSeq;
      this.orgType = orgJson.orgList[0].orgType;
    }
    //console.log(this.orgSeq,"orgSeq");
    //console.log(this.orgType,"orgType");
    if (this.orgType == 2) {
      //大区
      this.selfWarzoneCode = this.orgSeq;
    }
    console.log(
      'https://console.huaweicloud.com/dlv/vision/share/?id=00b5330241ec403faeb4920180d71a66&locale=zh-cn&region=cn-south-1#selfWarzoneCode=' +
        this.selfWarzoneCode,
      'hhhhh'
    );
  },
  methods: {
    // goadmin() {
    //   window.location.href =
    //     "http://10.51.4.60:8088/newRetailManageWeb/roleManage/roleListPage.html";
    // }
    clickimg() {
      window.open(
        'https://console.huaweicloud.com/dlv/vision/share/?id=00b5330241ec403faeb4920180d71a66&locale=zh-cn&region=cn-south-1#selfWarzoneCode=' +
          this.selfWarzoneCode
      );
    },
  },
};
</script>
<style lang="less" scoped>
iframe {
  width: 100%;
  height: 700px;
}
</style>
